﻿<UserControl x:Class="Tfl.Controls.WPF.StationIncidentsControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:vm="clr-namespace:Tfl.Controls.WPF.ViewModel" mc:Ignorable="d" 
             Background="Transparent"
             d:DesignHeight="300" d:DesignWidth="300"
             FontFamily="London Tube"
             FontSize="15"
             Foreground="White"
             d:DataContext="{d:DesignInstance vm:DesignTimeStationIncidentsViewModel, IsDesignTimeCreatable=True}"
             >
    <Grid>
        <Border Background="AntiqueWhite" BorderBrush="Black" BorderThickness="2" CornerRadius="15">
            <Border.Effect>
                <DropShadowEffect ShadowDepth="6" Direction="320"></DropShadowEffect>
            </Border.Effect>
            <Grid Margin="10,10,10,10">
                <Grid.RowDefinitions>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <TextBlock Grid.Row="0" Text="{Binding Path=Title}" Foreground="Black"></TextBlock>
                <ListBox Grid.Row="1" HorizontalContentAlignment="Stretch" Background="Black" ItemsSource="{Binding Path=Incidents}">
                    <ListBox.ItemTemplate>
                        <DataTemplate>
                            <StackPanel  Background="Black">
                                <StackPanel Orientation="Horizontal">
                                    <TextBlock Foreground="White" Text="{Binding Path=Name}"></TextBlock>
                                    <TextBlock Foreground="White" Margin="10,0,10,0">:</TextBlock>
                                    <TextBlock Foreground="White" Text="{Binding Path=Status}"></TextBlock>
                                </StackPanel>
                                <TextBlock Foreground="White" Text="{Binding Path=Description}"></TextBlock>
                            </StackPanel>
                        </DataTemplate>
                    </ListBox.ItemTemplate>
                </ListBox>
            </Grid>
        </Border>
    </Grid>
</UserControl>
